import allure
import json
from selenium.webdriver.common.by import By
from utils.timer import sleep

from page_element import Platformuser
from page_object.page_login import PageLogin

class Platform_school(PageLogin):
    # 基础登录点击内部管理
    nei_loc = (By.XPATH, '//*[@id="app"]/div/div[1]/div/div[2]/ul/li[3]')
    # 再点击平台管理
    ping_loc = (By.XPATH, '//*[@id="app"]/div/div[1]/div/div[2]/ul/li[1]')

    def test_nei(self):
        self.base_click(Platformuser.nei_loc)

    def test_ping(self):
        self.base_click(Platformuser.ping_loc)

    def test_ptzl(self, username, password):
        self.page_login(username, password)
        sleep(3)
        self.test_nei()
        sleep(3)
        self.test_ping()
        sleep(3)










